﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace QLNhaThuoc.DTO
{
    class Thuoc
    {
        public Thuoc()
        {
            _state = new ThuocNormalStockState(this);
        }

        private string _MaThuoc;

        public string MaThuoc
        {
            get { return _MaThuoc; }
            set { _MaThuoc = value; }
        }

        private string _Ten;

        public string Ten
        {
            get { return _Ten; }
            set { _Ten = value; }
        }

        private string _MaLoai;

        public string MaLoai
        {
            get { return _MaLoai; }
            set { _MaLoai = value; }
        }

        private int _DonGia;

        public int DonGia
        {
            get { return _DonGia; }
            set { _DonGia = value; }
        }

        private string _DonVi;

        public string DonVi
        {
            get { return _DonVi; }
            set { _DonVi = value; }
        }

        private string _MaCongTy;

        public string MaCongTy
        {
            get { return _MaCongTy; }
            set { _MaCongTy = value; }
        }

        private DateTime _NgaySanXuat;

        public DateTime NgaySanXuat
        {
            get { return _NgaySanXuat; }
            set { _NgaySanXuat = value; }
        }

        private DateTime _HanSuDung;

        public DateTime HanSuDung
        {
            get { return _HanSuDung; }
            set { _HanSuDung = value; }
        }

        private string _GhiChu;

        public string GhiChu
        {
            get { return _GhiChu; }
            set { _GhiChu = value; }
        }

        private ThuocState _state;

        public ThuocState State
        {
            get { return _state; }
            set { _state = value; }
        }

        private bool _TheoChiDinh;

        public bool TheoChiDinh
        {
            get { return _TheoChiDinh; }
            set { _TheoChiDinh = value; }
        }
        
        public int Sell(int sellQuantity)
        {
            return _state.Sell(sellQuantity);
        }

        public void Restock(int restockQuantity)
        {
            _state.Restock(restockQuantity);
        }
    }
}
